<!doctype html>
<html>
<head>
	<meta charset="utf-8">
	<title></title>
	<link rel="stylesheet" href="${staticServer}/inc/style/main.css" />
	<link rel="stylesheet" href="${staticServer}/inc/style/page.css" />
	<link rel="stylesheet" href="${staticServer}/css/work_today.css" />
	<link rel="stylesheet" href="${staticServer}/inc/style/date/datepicker.css" />
	<script src="${staticServer}/inc/js/jquery.js"></script>
	<script src="${staticServer}/inc/js/pageset.js"></script>
	<script src="${staticServer}/inc/js/datepicker.js"></script>
	<script src="${staticServer}/inc/js/infopad.js?2.2"></script>
	<script>
		/**
		* 查询方法
		*/
		function starquery(type){
			window.location.href="${contextPath}/index/blackphone.htm?phone="+$("#phone").val()+"&type="+type;
		}
	</script>
</head>

<body>
	<div id="home_link">
		<ul>
			<li>工作管理</li>
			<li>&gt;</li>
			<li class="current">竞思黑名单	</li>
		</ul>
	</div>
	<div id="container">
		<div id="title">黑名单</div>
		<table class="form_table">
			<tbody>
				<tr class="even_row">
					<td>
						<a href="${contextPath}/index/add_blackphone.htm"><input type="button" value=" 添加黑名单 "></a>
						<label>外部黑名人电话：</label>
						<input type="text" id="phone" size="15" value="" placeholder="请输入电话">
						<input type="button" value="查询外部黑名单 " onclick="starquery(2)">
						<#if webutil.getCookieUser().type=="1" || webutil.getCookieUser().type=="2" || webutil.getCookieUser().type=="3" || webutil.getCookieUser().username=="system" >
						<label>内部黑名人电话：</label>
						<input type="text" id="phone" size="15" value="" placeholder="请输入电话">
						<input type="button" value=" 查询内部黑名单 " onclick="starquery(1)">
						</#if>
					</td>
				</tr>
			</tbody>
		</table>
		
		<table>
			<tr class="fields">
				<th width="80">内部/外部</th>
				<th width="100">登记人姓名</th>
				<th width="100">登记人所属中心</th>
				<th width="100">黑名人</th>
				<th width="150">黑名人电话</th>
				<th width="100">原因</th>
				<th width="80">被标记次数</th>
				<th width="100">最近一次的标记时间</th>
				<th width="100">第一次标记时间</th>
			</tr>
			<#list list as list>
				<tr class="even_row">
					<td align="center">
						<#if list.type=="1">内部
							<#elseif list.type=="2">外部
						</#if>
					</td>
					<td align="center">${list.dj_name}</td>
					<td align="center">${list.center}</td>
					<td align="center">${list.name}</td>
					<td align="center">${list.phone}</td>
					<td align="center">${list.reason}</td>
					<td align="center">${list.is_cs}</td>
					<td align="center">${list.update_time}</td>
					<td align="center">${list.creat_time}</td>
				</tr>
			</#list>
		</table>
	</div>
	<div id="pager" style="width: 820px;">
	<ul id="pagination">
		<#if page??>
		<#if page.pagetotal?? && page.pagetotal!="0">
	<#assign pagetotal = page.pagetotal>
	<#else>
	<#assign pagetotal = 1>
	</#if>
	<#if page.currpage??>
	<#assign currpage = page.currpage>
	<#else>
	<#assign currpage = 1>
	</#if>
		<#if currpage==1 >
			<li class="previous-off">上一页</li>
			<#else>
			<li class="previous"><a href="${contextPath}/index/blackphone.htm?currPage=${currpage-1}&type=${type}">上一页</a></li>
			</#if>
		<#if pagetotal<=11>
			<#list 1..pagetotal as index_up>  
	           <#if currpage==index_up > 
	           		<li class="current">${index_up}</li>
	           <#else>
	           		<li><a href="${contextPath}/index/blackphone.htm?currPage=${index_up}&type=${type}">${index_up}</a></li>  
	           </#if>  
			</#list>  
		<#else>
			<#if currpage<=8 >
				<#list 1..9 as index_up>  
	           	<#if currpage==index_up >  
	            	<li class="current">${index_up}</li>
	           	<#else>  
	               <li><a href="${contextPath}/index/blackphone.htm?currPage=${index_up}&type=${type}">${index_up}</a></li> 
	           	</#if>
	           	</#list>  
	           	<li>...</li>
	           	<li><a href="${contextPath}/index/blackphone.htm?currPage=${pagetotal}&type=${type}">${pagetotal}</a></li>  
				
			<#elseif (currpage>= 9 && currpage<pagetotal-7)  >	
				<li><a href="${contextPath}/index/blackphone.htm?currPage=1&type=${type}">1</a></li>  
				<li>...</li>
				<#list currpage-3..currpage+3 as index_up>  
	           	<#if currpage==index_up >  
	             <li class="current">${index_up}</li>
	           	<#else>  
	               <li><a href="${contextPath}/index/blackphone.htm?currPage=${index_up}&type=${type}">${index_up}</a></li>  
	           	</#if>
	           	</#list>
				<li>...</li>
	           	<li><a href="${contextPath}/index/blackphone.htm?currPage=${pagetotal}&type=${type}">${pagetotal}</a></li>   
			<#else>
				<li><a href="${contextPath}/index/blackphone.htm?currPage=1&type=${type}">1</a></li> 
				<li>...</li>
				<#list pagetotal-8..pagetotal as index_up>  
	           	<#if currpage==index_up >  
	             <li class="current">${index_up}</li>
	           	<#else>  
	               <li><a href="${contextPath}/index/blackphone.htm?currPage=${index_up}&type=${type}">${index_up}</a></li> 
	           	</#if>
				</#list>  
			</#if>
		</#if> 
		<#if currpage==pagetotal >
		 	<li class="previous-off">下一页</li>
		<#else>
			<li class="previous"><a href="${contextPath}/index/blackphone.htm?currPage=${currpage+1}&type=${type}">下一页</a></li>
		</#if>
		<li class="pageinfo">共${page.total}条记录</li>
	</#if>
	</ul>
	</div>
	<div class="emptyline clear"></div>
</body>
</html>